/**
 * Created by Administrator on 2015/11/18.
 */
var mysql      = require('mysql');
//var connection = mysql.createConnection({
//    host     : 'localhost',
//    user     : 'root',
//    password : '',
//    database : 'nodejs'
//});

exports.getConnection = function(){
    var connection = mysql.createConnection({
        host     : 'localhost',
        user     : 'root',
        password : '',
        database : 'nodejs'
    });
    connection.connect();
    return connection;
}
